$OpenBSD: patch-configure,v 1.3 2017/02/27 01:42:06 bluhm Exp $
--- configure.orig	Fri Feb  9 07:07:26 2001
+++ configure	Mon Feb 27 02:09:54 2017
@@ -135,6 +135,21 @@ case "$UNAME_S" in
     ARFLAGS="-rc"
     SYSLIBS="-lnsl -lsocket"
     ;;
+  OpenBSD)
+    AR=ar
+    ARFLAGS="-rc"
+    if [ "$DEBUG" -ne 0 ]; then
+      CCDBG="-g -Wall"
+      LDDBG="-g -Wall"
+    else
+      CCDBG="-DNDEBUG"
+      LDDBG=""
+    fi
+    CFLAGS="${CCDBG} ${CFLAGS} -D_UNIX"
+    CXXFLAGS="${CCDBG} ${CXXFLAGS} -D_UNIX"
+    LD=ld
+    SYSLIBS="-pthread"
+    ;;
   *)
     CC=cc
     CFLAGS="-DNDEBUG -D_UNIX -I/usr/local/include"
